Optimal. Leaf size=39 \[ -\frac {2 \tanh ^{-1}\left (\frac {b+2 c x^n}{\sqrt {b^2-4 a c}}\right )}{\sqrt {b^2-4 a c} n} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 39, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.136, Rules used = {1366, 632, 212}
\begin {gather*} -\frac {2 \tanh ^{-1}\left (\frac {b+2 c x^n}{\sqrt {b^2-4 a c}}\right )}{n \sqrt {b^2-4 a c}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 632
Rule 1366
Rubi steps
\begin {align*} \int \frac {x^{-1+n}}{a+b x^n+c x^{2 n}} \, dx &=\frac {\text {Subst}\left (\int \frac {1}{a+b x+c x^2} \, dx,x,x^n\right )}{n}\\ &=-\frac {2 \text {Subst}\left (\int \frac {1}{b^2-4 a c-x^2} \, dx,x,b+2 c x^n\right )}{n}\\ &=-\frac {2 \tanh ^{-1}\left (\frac {b+2 c x^n}{\sqrt {b^2-4 a c}}\right )}{\sqrt {b^2-4 a c} n}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.06, size = 43, normalized size = 1.10 \begin {gather*} \frac {2 \tan ^{-1}\left (\frac {b+2 c x^n}{\sqrt {-b^2+4 a c}}\right )}{\sqrt {-b^2+4 a c} n} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(112\) vs.
\(2(35)=70\).
time = 0.06, size = 113, normalized size = 2.90
method | result | size |
risch | \(-\frac {\ln \left (x^{n}+\frac {b^{2}-4 a c +b \sqrt {-4 a c +b^{2}}}{2 c \sqrt {-4 a c +b^{2}}}\right )}{\sqrt {-4 a c +b^{2}}\, n}+\frac {\ln \left (x^{n}+\frac {b \sqrt {-4 a c +b^{2}}+4 a c -b^{2}}{2 c \sqrt {-4 a c +b^{2}}}\right )}{\sqrt {-4 a c +b^{2}}\, n}\) | \(113\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 73 vs.
\(2 (35) = 70\).
time = 0.35, size = 159, normalized size = 4.08 \begin {gather*} \left [\frac {\log \left (\frac {2 \, c^{2} x^{2 \, n} + b^{2} - 2 \, a c + 2 \, {\left (b c - \sqrt {b^{2} - 4 \, a c} c\right )} x^{n} - \sqrt {b^{2} - 4 \, a c} b}{c x^{2 \, n} + b x^{n} + a}\right )}{\sqrt {b^{2} - 4 \, a c} n}, -\frac {2 \, \sqrt {-b^{2} + 4 \, a c} \arctan \left (-\frac {2 \, \sqrt {-b^{2} + 4 \, a c} c x^{n} + \sqrt {-b^{2} + 4 \, a c} b}{b^{2} - 4 \, a c}\right )}{{\left (b^{2} - 4 \, a c\right )} n}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 4.31, size = 39, normalized size = 1.00 \begin {gather*} \frac {2 \, \arctan \left (\frac {2 \, c x^{n} + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{\sqrt {-b^{2} + 4 \, a c} n} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.47, size = 39, normalized size = 1.00 \begin {gather*} \frac {2\,\mathrm {atan}\left (\frac {b+2\,c\,x^n}{\sqrt {4\,a\,c-b^2}}\right )}{n\,\sqrt {4\,a\,c-b^2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________